package com.zl.web.action;

import com.opensymphony.xwork2.ActionContext;
import com.opensymphony.xwork2.ActionSupport;

/*
 * action 基类
 */
public class BaseAction extends ActionSupport{

	// 属性驱动方式接收参数
	private Integer pageCode = 1; // 当前页
	private Integer pageSize = 2; // 每页显示的条数
	public Integer getPageCode() {
		return pageCode;
	}
	public void setPageCode(Integer pageCode) {
		this.pageCode = pageCode;
	}
	public Integer getPageSize() {
		return pageSize;
	}
	public void setPageSize(Integer pageSize) {
		this.pageSize = pageSize;
	}
	
	/*
	 * 调用值栈对象set方法
	 */
	public void setVs(String key,Object obj){
		ActionContext.getContext().getValueStack().set(key, obj);
	}
	/*
	 * 调用值栈的push方法
	 */
	public void pushVs(Object obj){
		ActionContext.getContext().getValueStack().push(obj);
	}
}
